﻿<UserControl x:Class="EarthWatchers.SL.GUI.Controls.HexagonInfo"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
	xmlns:controls="clr-namespace:EarthWatchers.SL.GUI.Controls" mc:Ignorable="d" Visibility="Collapsed" Width="200" VerticalAlignment="Top" HorizontalAlignment="Left">
    <Grid x:Name="LayoutRoot" RenderTransformOrigin="0.5,0.5">
        <Grid.RenderTransform>
            <CompositeTransform/>
        </Grid.RenderTransform>

        <Grid Margin="0" VerticalAlignment="Top">
            <Grid.RowDefinitions>
                <RowDefinition Height="50" />
                <RowDefinition Height="Auto" />
                <RowDefinition Height="Auto" />
            </Grid.RowDefinitions>
            <Border CornerRadius="5,5,0,0" BorderThickness="1" BorderBrush="#FF858585" Margin="8,0,0,0" Canvas.ZIndex="3">
                <Border CornerRadius="5,5,0,0" BorderThickness="1" BorderBrush="#FF9bae30">
                    <Border CornerRadius="5,5,0,0" Background="{StaticResource GreenBg}">
                        <Grid>
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="Auto" />
                                <ColumnDefinition Width="Auto" />
                                <ColumnDefinition />
                            </Grid.ColumnDefinitions>
                            <Image Source="../../Resources/Images/user.png" Margin="12" Stretch="None" />
                            <StackPanel Orientation="Vertical" Grid.Column="1" Margin="0,10,0,10" VerticalAlignment="Center">
                                <TextBlock x:Name="txtName" FontWeight="Bold" FontSize="11" LineHeight="12" LineStackingStrategy="BlockLineHeight" TextWrapping="Wrap" Foreground="White" />
                                <TextBlock x:Name="txtCountry" FontSize="11" LineHeight="12" LineStackingStrategy="BlockLineHeight" TextWrapping="Wrap" Foreground="White" />
                            </StackPanel>
                            <Button Grid.Column="2" x:Name="btnClose" Margin="0,-2,0,0" Style="{StaticResource ImageButton}" ToolTipService.ToolTip="Cerrar" HorizontalAlignment="Right" VerticalAlignment="Top">
                                <Image x:Name="img" MouseLeftButtonDown="BtnCloseMouseLeftButtonDown" Source="/EarthWatchers.SL;component/Resources/Images/deletew.png" Stretch="None" />
                            </Button>
                        </Grid>
                    </Border>
                </Border>
            </Border>
            <Path Data="M 0,10 10,20 10,0 Z" Stroke="#FF849b0c" Fill="#FF849b0c" StrokeThickness="1" VerticalAlignment="Center" Canvas.ZIndex="4" />

            <Border x:Name="ActionButton" CornerRadius="0,0,5,5" BorderBrush="#FFcdcdcd" BorderThickness="1" Grid.Row="1" Margin="8,-2,0,0" Canvas.ZIndex="2">
                <Border.Background>
                    <LinearGradientBrush StartPoint="0.5,1" EndPoint="0.5,0">
                        <GradientStop Color="#FFe1ece3" Offset="0" />
                        <GradientStop Color="#FFFFFFFF" Offset="1" />
                    </LinearGradientBrush>
                </Border.Background>
                <Border Margin="12" BorderThickness="1" BorderBrush="#FFcdcdcd" CornerRadius="2" Cursor="Hand" MouseLeftButtonDown="Report_MouseLeftButtonDown">
                    <Border.Background>
                        <LinearGradientBrush StartPoint="0.5,1" EndPoint="0.5,0">
                            <GradientStop Color="#FFe9edea" Offset="0" />
                            <GradientStop Color="#FFFFFFFF" Offset="1" />
                        </LinearGradientBrush>
                    </Border.Background>
                    <Grid Margin="10">
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="42" />
                            <ColumnDefinition />
                        </Grid.ColumnDefinitions>
                        <Image x:Name="reportIcon" Source="/EarthWatchers.SL;component/Resources/Images/reportar.png" Stretch="None"/>
                        <TextBlock x:Name="reportText" Grid.Column="1" Text="REPORTAR" Foreground="#FF697d00" FontWeight="Bold" VerticalAlignment="Center" FontSize="12" />
                    </Grid>
                </Border>
            </Border>
            <Border CornerRadius="0,0,5,5" BorderBrush="#FFcdcdcd" BorderThickness="1" Grid.Row="2" Margin="8,-5,0,0" Canvas.ZIndex="1">
                <Border.Background>
                    <LinearGradientBrush StartPoint="0.5,1" EndPoint="0.5,0">
                        <GradientStop Color="#FFe8ece9" Offset="0" />
                        <GradientStop Color="#FFFFFFFF" Offset="1" />
                    </LinearGradientBrush>
                </Border.Background>
                <Grid Margin="0,17,0,0">
                    <Grid.RowDefinitions>
                        <RowDefinition />
                        <RowDefinition Height="Auto" />
                    </Grid.RowDefinitions>

                    <ItemsControl x:Name="commentList" BorderThickness="0" Background="Transparent" ScrollViewer.HorizontalScrollBarVisibility="Disabled" ScrollViewer.VerticalScrollBarVisibility="Disabled">
                        <ItemsControl.ItemTemplate>
                            <DataTemplate>
                                <StackPanel Orientation="Vertical" Margin="10,0,10,0">
                                    <TextBlock Text="{Binding FullName}" FontWeight="Bold" Foreground="#FF414141" FontSize="11" />
                                    <TextBlock Text="{Binding UserComment}" Foreground="#FF414141" FontSize="11" TextWrapping="Wrap" />
                                    <TextBlock Text="{Binding Published}" Foreground="#FF7c8e24" FontSize="11" />
                                    <Border BorderThickness="1" BorderBrush="#FFcdcdcd" Height="1" Margin="0,10,0,2" />
                                </StackPanel>
                            </DataTemplate>
                        </ItemsControl.ItemTemplate>
                    </ItemsControl>
                    <Button Grid.Row="1" x:Name="btnComments" Click="TxtCommentsClick" Style="{StaticResource ImageButton}" ToolTipService.ToolTip="Comentarios" HorizontalAlignment="Left" Margin="0,0,0,5">
                        <Grid>
                            <Image Source="/EarthWatchers.SL;component/Resources/Images/comments.png" Stretch="None"/>
                            <Ellipse
                                Margin="16,-15,0,0"
                                Width="15"
                                Height="15"
                                Fill="{StaticResource GreenBg}"
                                StrokeThickness="0">
                            </Ellipse>
                            <TextBlock x:Name="NumberOfCommentsText" Foreground="White" FontSize="11" Margin="20,-10,0,0" />
                        </Grid>
                    </Button>
                </Grid>
            </Border>



        </Grid>
    </Grid>
</UserControl>
